From 601e762973e9f79e6429f85804a9346d73f41bb8 Mon Sep 17 00:00:00 2001 From: Lapo Calamandrei Date: Sun, 14 Feb 2016 16:38:42 +0100 Subject: [PATCH] Adwaita: correct spacing for mixed buttons --- gtk/theme/Adwaita/_common.scss | 19 +++++++++++++++++-- gtk/theme/Adwaita/gtk-contained-dark.css | 22 ++++++++++++++++------ gtk/theme/Adwaita/gtk-contained.css | 22 ++++++++++++++++------ 3 files changed, 49 insertions(+), 14 deletions(-) diff --git a/gtk/theme/Adwaita/_common.scss b/gtk/theme/Adwaita/_common.scss index 723a057796..d2ecb8f299 100644 --- a/gtk/theme/Adwaita/_common.scss +++ b/gtk/theme/Adwaita/_common.scss @@ -461,8 +461,23 @@ button { // to have the image-button padding, while the text side the text-button // one, so we're adding the missing padding to the label depending on // its position inside the button - label:first-child { padding-left: 8px; } - label:last-child { padding-right: 8px; } + padding-left: 0; + padding-right: 0; + + label:first-child { + padding-left: 16px; + padding-right: 0; + } + + label:last-child { + padding-left: 0; + padding-right: 16px; + } + + image { + padding-left: 8px; + padding-right: 8px; + } } } diff --git a/gtk/theme/Adwaita/gtk-contained-dark.css b/gtk/theme/Adwaita/gtk-contained-dark.css index 929872665a..ddef74f673 100644 --- a/gtk/theme/Adwaita/gtk-contained-dark.css +++ b/gtk/theme/Adwaita/gtk-contained-dark.css @@ -494,12 +494,22 @@ notebook > header > tabs > arrow, headerbar button.titlebutton, .titlebar button.text-button.titlebutton, button.text-button { padding-left: 16px; padding-right: 16px; } - notebook > header > tabs > arrow.text-button.image-button label:first-child, headerbar button.text-button.image-button.titlebutton label:first-child, - .titlebar button.text-button.image-button.titlebutton label:first-child, button.text-button.image-button label:first-child { - padding-left: 8px; } - notebook > header > tabs > arrow.text-button.image-button label:last-child, headerbar button.text-button.image-button.titlebutton label:last-child, - .titlebar button.text-button.image-button.titlebutton label:last-child, button.text-button.image-button label:last-child { - padding-right: 8px; } + notebook > header > tabs > arrow.text-button.image-button, headerbar button.text-button.image-button.titlebutton, + .titlebar button.text-button.image-button.titlebutton, button.text-button.image-button { + padding-left: 0; + padding-right: 0; } + notebook > header > tabs > arrow.text-button.image-button label:first-child, headerbar button.text-button.image-button.titlebutton label:first-child, + .titlebar button.text-button.image-button.titlebutton label:first-child, button.text-button.image-button label:first-child { + padding-left: 16px; + padding-right: 0; } + notebook > header > tabs > arrow.text-button.image-button label:last-child, headerbar button.text-button.image-button.titlebutton label:last-child, + .titlebar button.text-button.image-button.titlebutton label:last-child, button.text-button.image-button label:last-child { + padding-left: 0; + padding-right: 16px; } + notebook > header > tabs > arrow.text-button.image-button image, headerbar button.text-button.image-button.titlebutton image, + .titlebar button.text-button.image-button.titlebutton image, button.text-button.image-button image { + padding-left: 8px; + padding-right: 8px; } button.osd { color: #eeeeec; border-radius: 5px; diff --git a/gtk/theme/Adwaita/gtk-contained.css b/gtk/theme/Adwaita/gtk-contained.css index f79b0d8dc0..c8e241037e 100644 --- a/gtk/theme/Adwaita/gtk-contained.css +++ b/gtk/theme/Adwaita/gtk-contained.css @@ -494,12 +494,22 @@ notebook > header > tabs > arrow, headerbar button.titlebutton, .titlebar button.text-button.titlebutton, button.text-button { padding-left: 16px; padding-right: 16px; } - notebook > header > tabs > arrow.text-button.image-button label:first-child, headerbar button.text-button.image-button.titlebutton label:first-child, - .titlebar button.text-button.image-button.titlebutton label:first-child, button.text-button.image-button label:first-child { - padding-left: 8px; } - notebook > header > tabs > arrow.text-button.image-button label:last-child, headerbar button.text-button.image-button.titlebutton label:last-child, - .titlebar button.text-button.image-button.titlebutton label:last-child, button.text-button.image-button label:last-child { - padding-right: 8px; } + notebook > header > tabs > arrow.text-button.image-button, headerbar button.text-button.image-button.titlebutton, + .titlebar button.text-button.image-button.titlebutton, button.text-button.image-button { + padding-left: 0; + padding-right: 0; } + notebook > header > tabs > arrow.text-button.image-button label:first-child, headerbar button.text-button.image-button.titlebutton label:first-child, + .titlebar button.text-button.image-button.titlebutton label:first-child, button.text-button.image-button label:first-child { + padding-left: 16px; + padding-right: 0; } + notebook > header > tabs > arrow.text-button.image-button label:last-child, headerbar button.text-button.image-button.titlebutton label:last-child, + .titlebar button.text-button.image-button.titlebutton label:last-child, button.text-button.image-button label:last-child { + padding-left: 0; + padding-right: 16px; } + notebook > header > tabs > arrow.text-button.image-button image, headerbar button.text-button.image-button.titlebutton image, + .titlebar button.text-button.image-button.titlebutton image, button.text-button.image-button image { + padding-left: 8px; + padding-right: 8px; } button.osd { color: #eeeeec; border-radius: 5px; -- 2.30.2